package cn.wolfcode.wolf2w.redis.service;

import cn.wolfcode.wolf2w.domain.TravelUserIdFavors;

import java.util.List;

public interface ITravelUserIdFavorsRedisService {

    /**
     * 判断redis中是否含有当前这个travelUserIdFavors的token
     * @param usid
     * @return
     */
    boolean isTravelUserIdFavorsExist(String usid);

    /**
     * 把travelUserIdFavors设置到redis中
     * @param travelUserIdFavors
     */
    void setTravelUserIdFavorsRedis(TravelUserIdFavors travelUserIdFavors);

    /**
     * 查找redis中全部的TravelUserIdFavors对象
     * @return
     */
    List<TravelUserIdFavors> findAllTravelUserIdFavors();

    /**
     * 把redis中所有得到travelUserIdFavors设置回mongodb
     * @param travelUserIdFavors
     */
    void setMongodb(List<TravelUserIdFavors> travelUserIdFavors);
}
